﻿using System;
using Avalonia.Controls;
using Avalonia.Interactivity;

namespace DocumentMaking.FluentNext.Views;

public partial class ErrorWindow : Window
{
    public ErrorWindow(Exception exception)
    {
        InitializeComponent();
        Block.Text = exception.ToString();
    }

    private void CopyClick(object? sender, RoutedEventArgs e)
    {
        Clipboard?.SetTextAsync(Block.Text);
    }
}